#include<func.h>
int main(void)
{
    sigset_t set;
    sigemptyset(&set);
    sigaddset(&set,SIGINT);
    sigprocmask(SIG_BLOCK,&set,NULL);
    sleep(5);
    //获取pending集合
    sigset_t pending;
    sigpending(&pending);
    if(sigismember(&pending,SIGINT))
    {
        printf("sigin is pending !\n");
    }
    else
    {
        printf("sigin is not pending\n");
    }
    //解除阻塞
    sigprocmask(SIG_UNBLOCK,&set,NULL);//
    return 0;
}